package eu.web.io.upload;

public class Field {
	String name;
	String value;
	UploadFile file;

	/**
	 * @param name
	 * @param value
	 */
	public Field(String name, String value) {
		super();
		this.name = name;
		this.value = value;
		file = null;
	}

	/**
	 * @param name
	 * @param file
	 */
	public Field(String name, UploadFile file) {
		super();
		this.name = name;
		this.file = file;
		value = null;
	}

	public boolean isCommon() {
		return value != null;
	}

	public boolean isFile() {
		return file != null;
	}

	public String getName() {
		return name;
	}

	public String getValue() {
		return value;
	}


	public UploadFile getFile() {
		return file;
	}

}
